package lc.com.lcpicturebackend.api.imagesearch;

import lc.com.lcpicturebackend.api.imagesearch.model.ImageSearchResult;
import lc.com.lcpicturebackend.api.imagesearch.sub.GetImageFirstUrlApi;
import lc.com.lcpicturebackend.api.imagesearch.sub.GetImageListApi;
import lc.com.lcpicturebackend.api.imagesearch.sub.GetImagePageUrlApi;

import java.util.List;

/**
 * 功能：
 * 作者：lc
 * 日期：2025/2/21 2:58
 */
public class ImageSearchApiFacade {

    public static List<ImageSearchResult> searchImage(String url)  {
        String imagePageUrl = GetImagePageUrlApi.getImagePageUrl(url);
        String imageFirstUrl = GetImageFirstUrlApi.getImageFirstUrl(imagePageUrl);
        return GetImageListApi.getImageList(imageFirstUrl);
    }
}
